<?php

require_once( ORM_DIR.'/StoredObject.php' );
require_once( ORM_DIR.'/StoredObjectDescriptor.php' );

interface Storage {
	
	public function refresh( StoredObject & $obj );
	public function save( StoredObject & $obj );
	public function create( StoredObject & $obj );
	public function remove( StoredObject & $obj );
	
	public function findByPrimaryKey( StoredObjectDescriptor & $desc, $primaryKey );
	public function findByFields( StoredObjectDescriptor & $desc, array $fields );
	
	public function removeAll( StoredObjectDescriptor & $desc );
}

?>